
public enum QuestionType {
	PERSONAL("personal"),
	EVENT("event"),
	THEORY("theory");
	
	private String name;
	
	private QuestionType(final String name) {
		this.name = name;
	}
	
	public static QuestionType to(final String type) {
		if (type.equalsIgnoreCase(PERSONAL.name)) {
			return PERSONAL;
                        //like dislike
		} else if (type.equalsIgnoreCase(EVENT.name)) {
			return EVENT;
                        // death-gossip
		} else if (type.equalsIgnoreCase(THEORY.name)) {
			return THEORY;
                        //guess
		}
		
		return null;
	}
}
